<template>
  <div class="popup" v-if="list.length > 0">
    <bookHeader>全部评论({{ list.length }})</bookHeader>
    <div class="comment-list">
      <commentList :list="list"></commentList>
    </div>
  </div>
</template>

<script>
import bookHeader from "@/components/bookHeader";
import commentList from "@/components/commentList";
export default {
  components: {
    bookHeader,
    commentList,
  },
  props: {
    list: {
      type: Array,
      default() {
        return [];
      },
    },
  },
};
</script>

<style lang="scss" scoped>
.popup {
  position: absolute;
  right: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  z-index: 1020;
  background-color: #fafafa;
}
.comment-list {
  padding: 50px 10px 0 10px;
}
</style>
